package com.zh.moUrl;


import org.junit.Test;

import javax.xml.rpc.ServiceException;
import java.rmi.RemoteException;

/**
 * model by zh
 * 测试在线订单工具url(这是啥0.0)
 */
public class zMoUrl {

    @Test
    public void chargeCalculate() {
        OrderOnlineToolServiceImplService onlineToolServiceImplService = new OrderOnlineToolServiceImplServiceLocator();
        try {
            IOrderOnlineToolService service = onlineToolServiceImplService.getOrderOnlineToolServiceImplPort();
            ChargeCalculateRequest chargeCalculateRequest = new ChargeCalculateRequest();
            chargeCalculateRequest.setCargoCode("102");
            ChargeCalculateResponse chargeCalculateResponse = service.chargeCalculateService(null, chargeCalculateRequest);
            System.out.println(chargeCalculateRequest.getProductCode());
        } catch (ServiceException e) {
            e.printStackTrace();
        } catch (RemoteException e) {
            e.printStackTrace();
        }
    }
}
